<?php
//http库
class TbfHttp {
    static function getContent($url){
        return file_get_contents($url);
    }

    static function redirect($url){
        TbfHttp::sendHttpCode(302);
        //已证实,此处不能简单的靠谱的转义url
        TbfRuntime::outHeader('Location',$url);
    }
    static function sendHttpCode($code){
        http_response_code($code);
    }
}
